<%--
  Created by IntelliJ IDEA.
  User: 27353
  Date: 2024/11/1
  Time: 17:15
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>Title</title>
    <link rel="stylesheet" href="/static/layui/css/layui.css" >
</head>
<body>
<form action="/student/addSave" method="post">
    <div class="layui-form-item">
        <div class="layui-inline">
            <label class="layui-form-label">学号</label>
            <div class="layui-input-inline layui-input-wrap">
                <input type="text" name="student_num" class="layui-input" required>
            </div>
        </div>
    </div>

    <div class="layui-form-item">
        <div class="layui-inline">
            <label class="layui-form-label">学生的名</label>
            <div class="layui-input-inline layui-input-wrap">
                <input type="text" name="student_name" class="layui-input" required>
            </div>
        </div>
    </div>

    <div class="layui-form-item">
        <div class="layui-inline">
            <label class="layui-form-label">性别</label>
            <div class="layui-input-inline layui-input-wrap">
                <select id="gender" name="gender" class="layui-input" required>
                    <option value="">请选择性别</option>
                    <option value="0">男</option>
                    <option value="1">女</option>
                    <option value="2">保密</option>
                </select>
            </div>
        </div>
    </div>

    <div class="layui-form-item">
        <div class="layui-inline">
            <label class="layui-form-label">年龄</label>
            <div class="layui-input-inline layui-input-wrap">
                <input type="text" name="age" class="layui-input" required>
            </div>
        </div>
    </div>

    <div class="layui-form-item">
        <div class="layui-inline">
            <label class="layui-form-label">出生日期</label>
            <div class="layui-input-inline layui-input-wrap">
                <input type="text" id="date_of_birth" name="date_of_birth" class="layui-input">
            </div>
        </div>
    </div>

    <div class="layui-form-item">
        <div class="layui-inline">
            <label class="layui-form-label">班级编号</label>
            <div class="layui-input-inline layui-input-wrap">
                <input type="text" name="class_id" class="layui-input" required>
            </div>
        </div>
    </div>

    <div class="layui-form-item">
        <div class="layui-inline">
            <label class="layui-form-label">宿舍编号</label>
            <div class="layui-input-inline layui-input-wrap">
                <input type="text" name="hostel_id" class="layui-input" required>
            </div>
        </div>
    </div>

    <div class="layui-form-item">
        <div class="layui-inline">
            <label class="layui-form-label">联系电话</label>
            <div class="layui-input-inline layui-input-wrap">
                <input type="text" name="phone" class="layui-input">
            </div>
        </div>
    </div>

    <div class="layui-form-item">
        <div class="layui-inline">
            <label class="layui-form-label">电子邮件地址</label>
            <div class="layui-input-inline layui-input-wrap">
                <input type="text" name="email" class="layui-input">
            </div>
        </div>
    </div>

    <div class="layui-form-item">
        <div class="layui-inline">
            <label class="layui-form-label">家庭住址</label>
            <div class="layui-input-inline layui-input-wrap">
                <input type="text" name="home_address" class="layui-input">
            </div>
        </div>
    </div>

    <div class="layui-form-item">
        <div class="layui-inline">
            <label class="layui-form-label">紧急联系人姓名</label>
            <div class="layui-input-inline layui-input-wrap">
                <input type="text" name="emergency_contact" class="layui-input">
            </div>
        </div>
    </div>

    <div class="layui-form-item">
        <div class="layui-inline">
            <label class="layui-form-label">紧急联系人联系电话</label>
            <div class="layui-input-inline layui-input-wrap">
                <input type="text" name="emergency_contact_phone" class="layui-input">
            </div>
        </div>
    </div>

    <div class="layui-form-item">
        <div class="layui-inline">
            <label class="layui-form-label">专业</label>
            <div class="layui-input-inline layui-input-wrap">
                <input type="text" name="major" class="layui-input">
            </div>
        </div>
    </div>

    <div class="layui-form-item">
        <div class="layui-inline">
            <label class="layui-form-label">学生状态</label>
            <div class="layui-input-inline layui-input-wrap">
                <select id="status" name="status" class="layui-input">
                    <option value="">请选择状态</option>
                    <option value="0">在读</option>
                    <option value="1">毕业</option>
                </select>
            </div>
        </div>
    </div>

    <div class="layui-form-item">
        <div class="layui-inline">
            <label class="layui-form-label">删除标志</label>
            <div class="layui-input-inline layui-input-wrap">
                <select id="del_flag" name="del_flag" class="layui-input">
                    <option value="">请选择状态</option>
                    <option value="0">存在</option>
                    <option value="1">删除</option>
                </select>
            </div>
        </div>
    </div>

    <div class="layui-form-item">
        <div class="layui-inline">
            <label class="layui-form-label">创建者</label>
            <div class="layui-input-inline layui-input-wrap">
                <input type="text" name="create_by" class="layui-input">
            </div>
        </div>
    </div>

    <div class="layui-form-item">
        <div class="layui-inline">
            <label class="layui-form-label">更新者</label>
            <div class="layui-input-inline layui-input-wrap">
                <input type="text" name="update_by" class="layui-input">
            </div>
        </div>
    </div>

    <div class="layui-form-item">
        <div class="layui-inline">
            <label class="layui-form-label">备注</label>
            <div class="layui-input-inline layui-input-wrap">
                <input type="text" name="remark" class="layui-input">
            </div>
        </div>
    </div>

    <div class="layui-form-item">
        <div class="layui-input-block">
            <button type="submit" class="layui-btn" lay-submit lay-filter="demo1">立即提交</button>
            <button type="reset" class="layui-btn layui-btn-primary">重置</button>
        </div>
    </div>
</form>
<script src="/static/layui/layui.js"></script>
<script>
    layui.use(['laydate', 'form'], function () {
        var laydate = layui.laydate;
        var form = layui.form;

        // 渲染日期选择器
        laydate.render({
            elem: '#date_of_birth',
            type: 'date',
            format: 'yyyy-MM-dd'
        });
        laydate.render({
            elem: '#create_time',
            type: 'datetime',
            format: 'yyyy-MM-dd HH:mm:ss'
        });
        laydate.render({
            elem: '#update_time',
            type: 'datetime',
            format: 'yyyy-MM-dd HH:mm:ss'
        });
    });
</script>


